package cn.li.controller;


import javax.persistence.Entity;
import javax.persistence.Table;

import com.thoughtworks.xstream.annotations.XStreamAlias;



@Entity
@Table(name = "Person")
@XStreamAlias("Person")
public class Person {

	private String name;
	 
	private int gender;
	
	
	public Person() {}
	
	
	public Person(String name, int gender) {
		this.name = name;
		this.gender = gender;
	}


	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public int getGender() {
		return gender;
	}

	public void setGender(int gender) {
		this.gender = gender;
	}

	/*public int hashCode() {
		return new HashCodeBuilder().append(name).append(gender).toHashCode();
	}*/

	@Override
	public String toString() {
		return "Person name:"+this.name+" gender:"+this.gender;
	}
}
